package com.magima.core.app;


public abstract class LazyLoadFragment extends BaseFragment{
	
    @Override
    public void setUserVisibleHint(boolean isVisibleToUser) {
        super.setUserVisibleHint(isVisibleToUser);
        if(getUserVisibleHint()) {
            onVisible();
        } else {
            onInvisible();
        }
    }
    

    protected void onVisible(){
        lazyLoad();
    }
    
    protected void onInvisible(){
    	
    }

    protected abstract void lazyLoad();

}
